package com.zegome.game.gomestory.main.scene.play.board;
import java.util.Vector;

public class DataMap {
		private Board board;
		public Pikachu[][] map;
		public int time;
		public int maxRow=10;
		public int maxCol=14;
		public int mapRow;
		public int mapCol;
		public Vector<InfoTypePika> infoTypePika;
		public int stylePlay;
		public int total;
		public int totalPikaFix;
		public float hiMap, wiMap;
		public float xBegin=0, yBegin=0;
		public float wi1Pikachu=50, hi1Pikachu=50;
		public int squareNor, squarePress;
		public float wiEdgeVer, hiEdgeVerUnit, wiEdgeHorUnit; 
		public float xBeginDraw, yBeginDraw;
		
		public DataMap(Board board, float wiMap, float hiMap, float xStart, float yStart){
			this.board = board;
			this.wiMap = wiMap;
			this.hiMap = hiMap;
			
			this.xBeginDraw = xStart;
			this.yBeginDraw = yStart;
			map = new Pikachu[10][14];
			for(int i=0;i<10;i++){
				for(int j=0;j<14;j++){
					map[i][j] = new Pikachu(board,0,0,(int)wi1Pikachu,(int)hi1Pikachu,i,j);
				}
			}
			infoTypePika = new Vector<InfoTypePika>();
		}
		
		public void countDown(int pika){
			for(int i=0;i<board.dataMap.infoTypePika.size();i++){
				if(board.dataMap.infoTypePika.elementAt(i).type==pika){
					board.dataMap.infoTypePika.elementAt(i).total-=2;
					break;
				}
			}
			board.dataMap.total-=2;
		}
		
		public void clear(){
			for(int i=0;i<10;i++){
				for(int j=0;j<14;j++){
					if(map[i][j]!=null)
						board.screen.removeChild(map[i][j]);					
				}
			}
		}
}
class Possition{
	int row;
	int col;
	public Possition(int row,int col){
		this.row = row;
		this.col = col;
	}
}

class InfoNumber{
	int numberPika;
	int weightPika;
	
	public InfoNumber(int number,int weight){
		this.numberPika = number;
		this.weightPika = weight;
	}
}
class InfoTypePika{
	int type;
	int total;
	public InfoTypePika(int type,int total){
		this.type = type;
		this.total = total;
	}
}